package com.zbkj.common.model.member;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import org.hibernate.validator.constraints.Range;

import javax.validation.constraints.DecimalMax;
import javax.validation.constraints.DecimalMin;
import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;

/**
 * <p>
 * 付费会员卡表
 * </p>
 *
 * @author hzw
 * @since 2024-05-10
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@TableName("eb_paid_member_card")
@ApiModel(value="PaidMemberCard对象", description="付费会员卡表")
public class PaidMemberCard implements Serializable {

    private static final long serialVersionUID=1L;

    @ApiModelProperty(value = "id")
    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;

    @ApiModelProperty(value = "会员卡名称")
    private String name;

    @ApiModelProperty(value = "卡片标签")
    private String label;

    @ApiModelProperty(value = "0-试用，1-期限，2-永久")
    private Integer type;

    @ApiModelProperty(value = "期限天数")
    private Integer deadlineDay;

    @ApiModelProperty(value = "会员卡原价")
    private BigDecimal originalPrice;

    @ApiModelProperty(value = "会员卡售价")
    private BigDecimal price;

    @ApiModelProperty(value = "是否仅首充赠送")
    private Boolean isFirstChargeGive;

    @ApiModelProperty(value = "赠送余额")
    private BigDecimal giftBalance;

    @ApiModelProperty(value = "排序")
    private Integer sort;

    @ApiModelProperty(value = "状态：1-开启，0-关闭")
    private Boolean status;

    @ApiModelProperty(value = "是否删除")
    private Boolean isDelete;

    @ApiModelProperty(value = "创建时间")
    private Date createTime;

    @ApiModelProperty(value = "更新时间")
    private Date updateTime;

    @ApiModelProperty(value = "品牌商ID（实际是sys_admin id）")
    private Integer brandId;

    @ApiModelProperty(value = "会员卡使用限制类型 0-无，1-次，2-天，3-周，4-月")
    private Integer useLimit;

    @ApiModelProperty(value = "会员卡使用限制数值")
    private Integer useLimitNum;

    @ApiModelProperty(value = "会员卡使用限制比例")
    private BigDecimal useLimitScale;

    @ApiModelProperty(value = "返利限制 0-无，1-次，2-天，3-周，4-月")
    private Integer rebateLimit;

    @ApiModelProperty(value = "返利条件数值")
    private Integer rebateNum;

    @ApiModelProperty(value = "折扣权益比例")
    private BigDecimal discount;


    @ApiModelProperty(value = "使用限制-分享同等身份数量")
    private Boolean isUseShareLimit;

    @ApiModelProperty(value = "分享同等身份数量")
    private Integer useShareLimitNum;

    //@ApiModelProperty(value = "返利限制-分享同等身份数量")
    @ApiModelProperty(value = "开启消费次数")
    private Boolean isRebateShareLimit;

    //@ApiModelProperty(value = "分享同等身份数量")
    @ApiModelProperty(value = "消费金额次数")
    private Integer rebateShareLimitNum;

    @ApiModelProperty(value = "是否跨品牌（0：否，1：是）")
    private Boolean isCrossBrand;


    //后续加
/*    @ApiModelProperty(value = "类别 1-商家券, 2-商品券, 3-通用券，4-品类券，5-品牌券，6-跨店券")
    private Integer category;*/

}
